/**
* @author:kellen
* @contact:xiekellen@hotmail.com
* @company:achivo-gz
* @created on:
* @modified on:
*/

package com.sasis.service.impl;

import java.util.List;

import com.sasis.service.impl.BaseManager;
import com.sasis.model.MsgType;
import com.sasis.dao.MsgTypeDao;
import com.sasis.service.MsgTypeManager;

import com.sasis.util.PageList;
import com.sasis.util.PageRequest;

public class MsgTypeManagerImpl extends BaseManager implements MsgTypeManager {
    private MsgTypeDao dao;

    /**
     * Set the Dao for communication with the data layer.
     * @param dao
     */
    public void setMsgTypeDao(MsgTypeDao dao) {
        this.dao = dao;
    }

    /**
     * @see com.sasis.service.MsgTypeManager#getMsgTypes(com.sasis.model.MsgType)
     */
    public List getMsgTypes(final MsgType msgType) {
        return dao.getMsgTypes(msgType);
    }

    /**
     * @see com.sasis.service.MsgTypeManager#getMsgType(String id)
     */
    public MsgType getMsgType(final String id) {
        return dao.getMsgType(new Integer(id));
    }

    /**
     * @see com.sasis.service.MsgTypeManager#saveMsgType(MsgType msgType)
     */
    public int saveMsgType(MsgType msgType) {
       return dao.saveMsgType(msgType);
    }

    /**
     * @see com.sasis.service.MsgTypeManager#removeMsgType(String id)
     */
    public void removeMsgType(MsgType msgType) {
        dao.removeMsgType( msgType);
    }
    public PageList queryForPageList(String listStatementId,  
    		Object parameterObject, PageRequest pageRequest){
	return dao.queryForPageList(listStatementId,   parameterObject, pageRequest);
    }
}
